package com.university.mentalhealthplatform.studentV3.ai.session;

import org.springframework.data.jpa.repository.JpaRepository;
import org.springframework.data.jpa.repository.Query;
import org.springframework.data.repository.query.Param;
import org.springframework.stereotype.Repository;

import java.util.List;

@Repository
public interface AiSessionRepository extends JpaRepository<AiSession, String> {

    @Query("SELECT s FROM AiSession s WHERE s.creatorId = :creatorId")
    List<AiSession> findByCreatorId(@Param("creatorId") String creatorId);
}